package com.hk.commons.entity.pay;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

/**
 * 
 * Title:PayRecord Description: 支付流水 Company:HK
 * 
 * @author Sam
 * @date 2016年6月3日下午5:29:14
 */
@Entity
@Table(name = "t_pay_record")
public class PayRecord implements Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = 8311345965124092049L;

	@Id
	@GeneratedValue(strategy = GenerationType.AUTO)
	private int id;

	/**
	 * 商户代码 [第三方支付公司的唯一识别码]
	 */
	@Column(length = 15)
	private String mchnt_cd; // 必传

	/**
	 * 订单号
	 */
	@Column(length = 30)
	private String orderId;// 必传

	/**
	 * 订单日期 YYYYMMDD
	 */
	@Column(length = 16)
	private String orderDate;// 必传

	/**
	 * 生成订单时间戳
	 */
	private Long cts;// 必传

	/**
	 * 交易金额
	 */
	@Column(length = 12)
	private String orderAmount;// 必传

	/**
	 * 订单状态 '00' – 订单已生成(初始状态) '01' – 订单已撤消 '02' – 订单已合并 '03' – 订单已过期 '04' –
	 * 订单已确认(等待支付) '05' – 订单支付失败 '11' – 订单已支付 '18' – 已发货 '19' – 已确认收货
	 */
	@Column(length = 2)
	private String orderStatus;// 必传

	/**
	 * 错误代码 【0000表示成功 其他失败】
	 */
	@Column(length = 30)
	private String orderPayCode;// 必传

	/**
	 * 错误中文描述
	 */
	@Column(length = 80)
	private String orderPayError;// 必传

	/**
	 * 保留字段
	 */
	@Column(length = 40)
	private String resv1;

	/**
	 * 富友流水号 供商户查询支付交易状态及对账用
	 */
	@Column(length = 30)
	private String fySSn;// 必传

	/**
	 * MD5摘要数据
	 */
	@Column(length = 40)
	private String md5;// 必传

	/**
	 * 用户ID
	 */
	@Column(length = 20)
	private String userId;// 必传

	/**
	 * 渠道 1. 富友
	 */
	private int channce;

	/**
	 * 失败原因
	 */
	@Column(length = 20)
	private String failReason;

	/**
	 * 卡号
	 */
	@Column(length = 20)
	private String cardNo;// 必传

	public int getId() {
		return id;
	}

	public void setId(int id) {
		this.id = id;
	}

	public String getMchnt_cd() {
		return mchnt_cd;
	}

	public void setMchnt_cd(String mchnt_cd) {
		this.mchnt_cd = mchnt_cd;
	}

	public String getOrderId() {
		return orderId;
	}

	public void setOrderId(String orderId) {
		this.orderId = orderId;
	}

	public String getOrderDate() {
		return orderDate;
	}

	public void setOrderDate(String orderDate) {
		this.orderDate = orderDate;
	}

	public Long getCts() {
		return cts;
	}

	public void setCts(Long cts) {
		this.cts = cts;
	}

	public String getOrderAmount() {
		return orderAmount;
	}

	public void setOrderAmount(String orderAmount) {
		this.orderAmount = orderAmount;
	}

	public String getOrderStatus() {
		return orderStatus;
	}

	public void setOrderStatus(String orderStatus) {
		this.orderStatus = orderStatus;
	}

	public String getOrderPayCode() {
		return orderPayCode;
	}

	public void setOrderPayCode(String orderPayCode) {
		this.orderPayCode = orderPayCode;
	}

	public String getOrderPayError() {
		return orderPayError;
	}

	public void setOrderPayError(String orderPayError) {
		this.orderPayError = orderPayError;
	}

	public String getResv1() {
		return resv1;
	}

	public void setResv1(String resv1) {
		this.resv1 = resv1;
	}

	public String getFySSn() {
		return fySSn;
	}

	public void setFySSn(String fySSn) {
		this.fySSn = fySSn;
	}

	public String getMd5() {
		return md5;
	}

	public void setMd5(String md5) {
		this.md5 = md5;
	}

	public String getUserId() {
		return userId;
	}

	public void setUserId(String userId) {
		this.userId = userId;
	}

	public int getChannce() {
		return channce;
	}

	public void setChannce(int channce) {
		this.channce = channce;
	}

	public String getFailReason() {
		return failReason;
	}

	public void setFailReason(String failReason) {
		this.failReason = failReason;
	}

	public String getCardNo() {
		return cardNo;
	}

	public void setCardNo(String cardNo) {
		this.cardNo = cardNo;
	}

}
